#ifndef REGISTERWIN_H
#define REGISTERWIN_H

#include <QMainWindow>
#include <QMutexLocker>

namespace Ui {
class RegisterWin;
}



class RegisterWin : public QMainWindow
{
    Q_OBJECT
public:
    explicit RegisterWin(QWidget *parent = 0);
    ~RegisterWin();
    bool checkRegister();
    void widgetCenter(QWidget *pWidget,QWidget*parent = nullptr);
    void showHintLabel(QWidget *parent,
                              QString strText,
                              QString strFontSize = "12px",
                              QString strColor = "#ffffff",
                              QString strBgColor = "#202020"); //一个提示便签  会淡化消失
    static int const Pass_Register;
private slots:
    void on_pushButton_shutDown_clicked();
    void on_pushButton_turn2_clicked();
    void on_pushButton_turn1_clicked();
    void on_pushButton_Ok_clicked();

private:
    Ui::RegisterWin *ui;
    QString getWMIC(const QString &cmd);
    QString getCpuName();
    QString getCpuId();
    QString getCpuCoresNum();
    QString getCpuLogicalProcessorsNum();
    QString getDiskNum();
    QString getBaseBordNum();
    QString getBiosNum();
    QString HexToHexstr(const QByteArray hex);
    QString caculateRegister(QString serial, QByteArray keyData);
};

#endif // REGISTERWIN_H
